#!/bin/sh
function foo() {
 echo "Write in function"
}

echo 'Out function'
foo
echo 'end'

exit 0

// yes_or_no

#!/bin/sh
yes_or_no()
{
  echo "Is your name $* ?"
  echo "$1, $2"
  while true
  do
    echo -n "Enter yes or no: "
    read x
    case "$x" in
      y | yes ) return 0;;
      n | no  ) return 1;;
      *       ) echo "Answers can only be yes or no";;
      esac
  done
}
echo "Original parameters are $*"
if yes_or_no "abc" "cde"
then
  echo "Hi $1, nice name."
else
  echo "Never mind."
fi
echo "Original parameters are $1"
exit 0
